package com.dl.code.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.List;

@TableName(value = "permission")
public class Permission {

  @TableId(value = "permission_id",type = IdType.AUTO)
  private Integer permissionId;
  private String permissionName;
  @TableField(exist = false)
  private List<Role> roleList;


  public Integer getPermissionId() {
    return permissionId;
  }

  public void setPermissionId(Integer permissionId) {
    this.permissionId = permissionId;
  }

  public String getPermissionName() {
    return permissionName;
  }

  public void setPermissionName(String permissionName) {
    this.permissionName = permissionName;
  }

  @Override
  public String toString() {
    return "Permission{" +
            "permissionId=" + permissionId +
            ", permissionName='" + permissionName + '\'' +
            ", roleList=" + roleList +
            '}';
  }
}
